//
//  SSOrderDetailCell.swift
//  拾舍清洁
//
//  Created by sky.wei on 2023/3/5.
//

import UIKit

class SSOrderDetailCell: UITableViewCell {
    
    var isImage:Bool = false
    
    
    @IBOutlet weak var copyImg: UIImageView!
    @IBOutlet weak var detailLeading: NSLayoutConstraint!
    
    @IBOutlet weak var titleLab: UILabel!
    @IBOutlet weak var detailLab: UILabel!
    override func awakeFromNib() {
        super.awakeFromNib()

        copyImg.isUserInteractionEnabled = true
        let tap = UITapGestureRecognizer(target: self, action: #selector(tapedTitleLabel(_:)))
        copyImg.addGestureRecognizer(tap)
        
    }
    
    @objc private func tapedTitleLabel(_ tapGes : UITapGestureRecognizer) {
       print("----")
        UIPasteboard.general.string = detailLab.text
        UIViewController.current().view.makeToast("复制成功")
    }


    
    public override func layoutSubviews() {
        super.layoutSubviews()
        detailLeading.constant = copyImg.isHidden ? 16 : 48
    }
    
}
